feat: add keyboard theme picker with 37 themes across 6 sections#644
feat: add keyboard theme picker with 37 themes across 6 sections#644prince-0408 wants to merge 2 commits intoscribe-org:mainfrom
Conversation
- Add KeyboardTheme struct with ThemeCategory enum (Classic, Dark, Light, Gradient, Neon, Nature, Cultural, Accessible) - Add ThemeManager to persist and apply themes via shared UserDefaults - Add 37 built-in themes including gradient, neon, cultural (Berlin, Paris, Madrid, Stockholm) and accessible (HC Dark, HC Light, Warm AA) themes - Add ThemePickerViewController with Gboard-style sectioned 3-column grid, CAGradientLayer previews for gradient themes, and system-adaptive colors - Wire theme picker into Settings tab with live theme name subtitle - Hook ThemeManager.loadSavedTheme() into keyboard load and trait change - Add keyboardTheme case to UserInteractiveState and SectionState handling
Thank you for the pull request! 💙🩵The Scribe-iOS team will do our best to address your contribution as soon as we can. The following are some important points:
Note Scribe uses Conventional Comments in reviews to make sure that communication is as clear as possible. |
Maintainer ChecklistThe following is a checklist for maintainers to make sure this process goes as well as possible. Feel free to address the points below yourself in further commits if you realize that actions are needed :) |
- Add messages to all fatalError calls (fatal_error_message rule) - Refactor drawKey to use CGRect parameter instead of x/y/w/h to reduce parameter count below the 5-param limit (function_parameter_count rule)
|
Hi @prince-0408 👋 We talked about this and are going to close this and decline #643. Specifically there's a big issue with this feature, which is that we have the noun-gender annotations that are also colored in specific ways. The colors of the keyboard being similar to the system keyboard means that these annotation colors are clear, but if we use these, then they're going to blend in and the user experience is going to suffer. Setting all of this up so that the annotations work across these themes isn't something we're interested in doing at this time. |
|
Hi @andrewtavis, thanks for the detailed explanation. I understand the concern about the noun-gender annotation colors blending in with the themed keyboard colors. I'll keep this in mind for any future contributions. Appreciate the feedback! |
Summary
Adds a complete keyboard theme customization system to Scribe-iOS, allowing users to personalize the appearance of all installed language keyboards from the Settings tab.
Closes #643
Changes
New Files
Keyboards/KeyboardsBase/KeyboardTheme.swiftKeyboardThemestruct,ThemeCategoryenum, 37 built-in themes, andThemeManagerfor persistence and applicationScribe/Themes/ThemePickerViewController.swiftModified Files
KeyboardViewController.swiftThemeManager.shared.loadSavedTheme()on load and on trait changeSettingsTableData.swiftSettingsViewController.swiftThemePickerViewControlleron theme row tapInfoChildTableViewCell.swiftParentTableCellModel.swift.keyboardThemetoUserInteractiveStateTheme Categories
How It Works
ThemePickerViewControllerpresents a sectioned grid of theme cardsThemeManager.shared.apply(theme), which mutates the global color vars and saves the theme ID to the sharedUserDefaultsapp groupThemeManager.shared.loadSavedTheme()to read the saved ID and re-apply colors before renderingTesting
ScreenShot